home *** CD-ROM | disk | FTP | other *** search
/ Chip: Hang es video / CHIP_ZENESZERKESZTO_2005.ISO / audio_3 / visual / robotfunk / setup.exe / {app} / main.dxr / Internal_47.ls < prev    next >
Encoding:
Text File  |  2003-11-19  |  1.4 KB  |  54 lines

  1. property spriteNum, sm, dualenabled
  2. global softdual, fs, fsim, fsrect, secondwidth, secondheight
  3.  
  4. on beginSprite me
  5.   dualenabled = 0
  6.   sprite(spriteNum).member.hilite = 0
  7.   sm = sprite(spriteNum).member
  8.   softdual = 0
  9.   if (the desktopRectList).count > 1 then
  10.     dualenabled = 1
  11.     fs = window("fullscreen")
  12.     fs.windowType = 2
  13.     fs.rect = (the desktopRectList)[2]
  14.     case fs.rect.width of
  15.       800:
  16.         fs.drawRect = rect(0, 0, 800, 600)
  17.       640:
  18.         fs.drawRect = rect(0, 0, 640, 480)
  19.     end case
  20.     fs.open()
  21.     fsim = fs.image
  22.     case (the desktopRectList)[2].height of
  23.       480:
  24.         fsrect = rect(-800, 0, -160, 480)
  25.       600:
  26.         fsrect = rect(-800, 0, 0, 600)
  27.       otherwise:
  28.         fsrect = rect(-800, 0, 0, 600)
  29.     end case
  30.     secondwidth = (the desktopRectList)[2].width
  31.     secondheight = (the desktopRectList)[2].height
  32.   else
  33.     if ((the desktopRectList)[1].width / float((the desktopRectList)[1].height)) > 2.60000000000000009 then
  34.       fs = window("fullscreen")
  35.       dualenabled = 1
  36.       lerect = rect((the desktopRectList)[1].width / 2.0, 0, (the desktopRectList)[1].right, (the desktopRectList)[1].height)
  37.       fs.rect = lerect
  38.       fsrect = lerect
  39.       fs.open()
  40.       fsim = fs.image
  41.       secondwidth = lerect.width
  42.       secondheight = lerect.height
  43.     end if
  44.   end if
  45. end
  46.  
  47. on mouseUp me
  48.   if dualenabled = 1 then
  49.     softdual = not softdual
  50.   else
  51.     sm.hilite = 0
  52.   end if
  53. end
  54.